/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * DinnerApplet.java
 *
 * Created on 14.03.2010, 10:45:06
 */

package dinner.web.gui.applets;

import javax.swing.JOptionPane;
import org.bizon.dinner.common.gui.DinnerPanel;

/**
 * 
 * @author Bizon
 */
public class DinnerApplet extends javax.swing.JApplet {

	/** Initializes the applet DinnerApplet */
	public void init() {
		try {
                    NBimpl.init();
			java.awt.EventQueue.invokeAndWait(new Runnable() {
				public void run() {
					initComponents();
					jScrollPane1.setViewportView(new DinnerPanel());
				}
			});
		} catch (Throwable ex) {
			ex.printStackTrace();
                        JOptionPane.showMessageDialog(null, ex.getMessage() + "\n" + ex.toString());
		}
	}

	/**
	 * This method is called from within the init() method to initialize the
	 * form. WARNING: Do NOT modify this code. The content of this method is
	 * always regenerated by the Form Editor.
	 */
	@SuppressWarnings("unchecked")
	// <editor-fold defaultstate="collapsed"
	// desc="Generated Code">//GEN-BEGIN:initComponents
	private void initComponents() {

		jScrollPane1 = new javax.swing.JScrollPane();

		javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
		getContentPane().setLayout(layout);
		layout.setHorizontalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(
				layout.createSequentialGroup().addContainerGap().addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 380, Short.MAX_VALUE)
						.addContainerGap()));
		layout.setVerticalGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(
				layout.createSequentialGroup().addContainerGap().addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 278, Short.MAX_VALUE)
						.addContainerGap()));
	}// </editor-fold>//GEN-END:initComponents

	// Variables declaration - do not modify//GEN-BEGIN:variables
	private javax.swing.JScrollPane jScrollPane1;
	// End of variables declaration//GEN-END:variables

       static  public void main(String args[]){
           DinnerApplet applet =  new DinnerApplet();
           applet.init();
           applet.setVisible(true);
        }
}
